package com.lxh.lxhcrm.model.mappers.productManagement;

import com.lxh.lxhcrm.model.pojos.DeliveryPlan;
import com.lxh.lxhcrm.model.pojos.InWare;
import com.lxh.lxhcrm.model.pojos.OutWare;
import com.lxh.lxhcrm.model.pojos.ProDetail;
import org.springframework.data.repository.query.Param;

import java.util.List;

public interface WareMapper {
    /*
     * 查询
     * */
    //出库表查询
    List<OutWare> findOutWare(@Param("searchText")String searchText, @Param("selectModel")Integer selectModel,@Param("judge")Integer judge);
    //无分页查询出库
    List<OutWare> allOutWare();
    //入库表查询
    List<InWare> findInWare(@Param("searchText")String searchText, @Param("selectModel")Integer selectModel, @Param("judge")Integer judge);
    //无分页查询入库
    List<InWare> allInWare();
    //查询所有交付计划，入库所需
    List<DeliveryPlan> findDeliveryPlan();
    /*
     * 修改
     * */
    //修改出库表状态
    void changeOutState(@Param("judge")Integer judge,Integer outId);
    //修改入库表状态
    void changeInState(@Param("judge")Integer judge,Integer inId);
    //出入库完成,修改产品数量
    void changeProNum(Integer proDetailId,Integer wareNum,Integer proNum);
    //入库完成,修改交付计划状态
    void changeDeliveryPlan(Integer isOut,Integer deliveryPlanId);
}
